package com.twu.biblioteca.options;

import com.twu.biblioteca.library.Library;
import com.twu.biblioteca.streams.AppOutputStream;

import java.io.IOException;

public class ViewAllBooks implements Option {

    @Override
    public void execute() throws IOException {
        String allBooks = Library.getLibrary().viewAllBooks();
        AppOutputStream.writeLine(allBooks);
    }

    @Override
    public String toString() {
        return "View All Books";
    }
}
